pluginConfig
This read-only property is added to all Grails artefacts provided by plugins.
Artefacts can use this to access the configuration values that pertain to their plugin only.
Example:
1 2 3 4 5 6 7 | class MyPluginService { def doSomething() { if (pluginConfig.enabled) { println "It worked!" } } } |
This provides a valuable shortcut to accessing config that removes the responsibility to maintain this information from your code.